﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using FluentNHibernate.Mapping;

namespace TitipNyobaYan.Models
{
    class REVIEWMap:ClassMap<REVIEW>
    {
        public REVIEWMap()
        {
            Table("REVIEW");
            LazyLoad();
            Id(x => x.ID_REVIEW).GeneratedBy.Assigned().Column("ID_REVIEW");
            //Map(x => x.ISBN_BUKU).Column("ISBN_BUKU").Length(30);
            Map(x => x.ISI_REVIEW).Column("ISI_REVIEW").Length(160);
            Map(x => x.TANGGAL_REVIEW).Column("TANGGAL_REVIEW");
            References(x => x.ORANG_REVIEW).ForeignKey("ORANG_REVIEW");
            References(x => x.ISBN_BUKU).ForeignKey("ISBN_BUKU");
        }
    }
}
